<template>
	<view>
		<view>
			<button type="primary" @click="uploadImg">点击上传</button>
		</view>
		<view>
			<image v-for="item in imgArr" :src="item" @click="showImg(item)"></image>
		</view>
	</view>
</template>

<script>
		
	export default {
		onLoad(options) {
			console.log(options)
		},
		data() {
			return {
				imgArr:[]
			}
		},
		methods: {
			uploadImg(){
				uni.chooseImage({
					count:9,
					success:res=> {
						this.imgArr=res.tempFilePaths
					}
				})
			},
			showImg(current){
				uni.previewImage({
					urls:this.imgArr,
					current:current
				})
			}
			
		}
	}
</script>

<style>

</style>
